﻿<%@ Page Title="" Language="C#" Inherits="System.Web.Mvc.ViewPage<Framework.Mvc.UserRegisterViewModel>" %>

<html>
<head>
    <script type="text/javascript" src="/Scripts/jquery-1.4.2.min.js"></script>
    <script type="text/javascript">
        $(document).ready(function () {
            $('.ServiceProjectClass').each(function (index, element) {
                $(element).click(function (item) {
                    var c = "";
                    $('.ServiceProjectClass').each(function (index, element) {
                        if ($(element).attr("checked")) {
                            c += $(element).attr("value") + "|";
                        }
                    });
                    c = c.substring(0, c.length - 1);
                    $("input[name='instance.ServiceProject']").val(c);
                });
            });
        });
    </script>
</head>
<body>
    <%using (Html.BeginForm())
      {
    %>
    <%: Html.ValidationSummary(true) %>
    用户名:<%: Html.TextBoxFor(m => m.Instance.Name) %><%: Html.ValidationMessageFor(m => m.Instance.Name)%><br />
    <br />
    密码:<%: Html.PasswordFor(m => m.Instance.Password) %><%: Html.ValidationMessageFor(m => m.Instance.Password)%><br />
    <br />
    新人姓名:<%: Html.TextBoxFor(m => m.Instance.DisplayName)%><%: Html.ValidationMessageFor(m => m.Instance.DisplayName)%><br />
    <br />
    手机:<%: Html.TextBoxFor(m => m.Contact.Mobile) %><%: Html.ValidationMessageFor(m => m.Contact.Mobile)%><br />
    <br />
    QQ:<%: Html.TextBoxFor(m => m.Contact.QQ) %><%: Html.ValidationMessageFor(m => m.Contact.QQ)%><br />
    <br />
    MSN:<%: Html.TextBoxFor(m => m.Contact.MSN) %><%: Html.ValidationMessageFor(m => m.Contact.MSN)%><br />
    <br />
    时间:<br />
    <br />
    未定服务项目:<input class="ServiceProjectClass" type="checkbox" value="婚庆" />婚庆
    <input class="ServiceProjectClass" type="checkbox" value="婚纱" />婚纱
    <input class="ServiceProjectClass" type="checkbox" value="家俱" />家俱
    <input class="ServiceProjectClass" type="checkbox" value="装修" />装修
    <%: Html.ValidationMessageFor(m => m.Instance.ServiceProject) %>
    <input name="instance.ServiceProject" type="hidden" value="ServiceProject" />
    <input type="submit" value="注册" />
    <br />
    <br />
    <% 
      } 
    %>
</body>
</html>
